<script>
import GroupCard from '@/components/FreeForm/design/form/form-group/group-card/index.vue'

export default {
  name: 'FormGroup',
  components: { GroupCard },
  props: {
    groups: {
      type: Array,
      default: () => {
        return []
      }
    }
  },
  methods: {
    clickElement(element) {
      this.$emit('click-element', element)
    },
    refresh() {
      this.$emit('refresh')
    }
  }
}
</script>

<template>
  <div>
    <group-card
      v-for="group in groups"
      :key="group.id"
      :group="group"
      @clickElement="clickElement"
      v-on="$listeners"
    />
  </div>
</template>

<style scoped lang="scss">

</style>
